package com.apexedu.biz.entity;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * 用户信息
 * Created by ly on 2014/11/1.
 */
@Entity
@Table(name = "T_SYS_USER_INFO")
public class TSysUserInfo implements Serializable {
    private String userid;
    private Integer yhlx; //用户类型
    private Long liferayuserid; //liferay的user_表的组件
    private String phone; //手机号
    private String email; //电子邮箱
    private Date lastlogintime; //最后一次登录时间
    private String updatepwd; //是否更新过密码 1为是 0为否

    public TSysUserInfo() {
    }

    public TSysUserInfo(String userid, Integer yhlx) {
        this.userid = userid;
        this.yhlx = yhlx;
    }

    public TSysUserInfo(String userid, Integer yhlx, Long liferayuserid, String phone, String email, Date lastlogintime, String updatepwd) {
        this.userid = userid;
        this.yhlx = yhlx;
        this.liferayuserid = liferayuserid;
        this.phone = phone;
        this.email = email;
        this.lastlogintime = lastlogintime;
        this.updatepwd = updatepwd;
    }

    @Id
    @Column(name = "USERID")
    public String getUserid() {
        return userid;
    }

    public void setUserid(String userid) {
        this.userid = userid;
    }

    @Basic
    @Column(name = "YHLX")
    public Integer getYhlx() {
        return yhlx;
    }

    public void setYhlx(Integer yhlx) {
        this.yhlx = yhlx;
    }

    @Basic
    @Column(name = "LIFERAYUSERID")
    public Long getLiferayuserid() {
        return liferayuserid;
    }

    public void setLiferayuserid(Long liferayuserid) {
        this.liferayuserid = liferayuserid;
    }

    @Basic
    @Column(name = "PHONE")
    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    @Basic
    @Column(name = "EMAIL")
    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    @Basic
    @Column(name = "LASTLOGINTIME")
    public Date getLastlogintime() {
        return lastlogintime;
    }

    public void setLastlogintime(Date lastlogintime) {
        this.lastlogintime = lastlogintime;
    }

    @Basic
    @Column(name = "UPDATEPWD")
    public String getUpdatepwd() {
        return updatepwd;
    }

    public void setUpdatepwd(String updatepwd) {
        this.updatepwd = updatepwd;
    }

    @Override
    public String toString() {
        return "TSysUserInfo{" +
                "userid='" + userid + '\'' +
                ", yhlx=" + yhlx +
                ", liferayuserid=" + liferayuserid +
                ", phone='" + phone + '\'' +
                ", email='" + email + '\'' +
                ", lastlogintime=" + lastlogintime +
                ", updatepwd='" + updatepwd + '\'' +
                '}';
    }
}
